import sqlite3



def print_hi(name):
    # Use a breakpoint in the code line below to debug your script.
    print(f'Hi, {name}')  # Press Ctrl+F8 to toggle the breakpoint.
    # 连接数据库
    conn = sqlite3.connect('example.db')

    # 创建游标对象
    cursor = conn.cursor()

    # 执行SQL语句
    cursor.execute('''CREATE TABLE IF NOT EXISTS users 
                      (id INTEGER PRIMARY KEY, name TEXT, age INTEGER)''')

    cursor.execute("insert into users Values(111,'黑鱼',10 )")
    cursor.execute("select * from users")  # 对T_fish表执行数据查找命令
    for row in cursor.fetchall():  # 以一条记录为元组单位返回结果给row
        print(row)
    # conn.commit()
    conn.close()  # 关闭数据库


import site
import os

for site_dir in site.getsitepackages():
    print(site_dir)



if __name__ == '__main__':
    print_hi('PyCharm')
    # 输出用户级别的site-packages目录
    print(site.getusersitepackages())


